package com.test.future;

/**
 * 客户端程序
 * 
 * @author xuguangqiao
 *
 */
public class Client {

	public Data request(final String queryStr) {
		final FutureData future = new FutureData();
		new Thread() {
			public void run() {
				RealData realData = new RealData(queryStr);
				future.setRealData(realData);
			};
		}.start();

		return future;//FutureData会立即返回
	}
}
